package com.lhnstart.learn.bases.exception;

/**
 * try demo
 *
 * @author lhn
 * @date 2023/07/20 20:35
 * @since 1.0.0
 **/
public class TryDemo {

    public static void main(String[] args) {
        try {
            String str = "1";
            int a = Integer.parseInt(str);
            System.out.println(a);
        } catch (NumberFormatException e) {
            throw new RuntimeException(e);
        } finally {
            int i1 = 10;
            int i2 = 0;
            System.out.println(i1 / i2);
        }
        System.out.println(12);
    }

}